package com.knife.blog.domain;
import com.knife.dbo.IObject;
import java.io.Serializable;
import java.text.SimpleDateFormat;
public class Photo implements IObject,Serializable {
	
	private static final SimpleDateFormat df = new SimpleDateFormat("yyyyMMdd");

  //EasyJWeb Tools自动代码生成
  //属性部份

  	private String cid;
  	private String title;
  	private String dirid;
  	private String resourceid;
  	private String url;
  	private String s_url;
  	private String htmlurl;
  	private java.util.Date inputtime;
  	private String inputuser;
  	private Integer readtimes;
  	private Integer replynum;
  	private String intro;
  	private Integer status;
  	private String blogcid;
  	private String circlesn;
  
//EasyDBO自动映射部份
	public String getTableName() {
		return "photo";
	}

	public String getKeyField() {
		return "cid";
	}

	public String getKeyGenerator() {
		return "com.knife.dbo.RandomIdGenerator";
	}

//getter及setter方法

 	public String getCid() {
		return cid;
	}

	public void setCid(String cid) {
		this.cid = cid;
	}
  	public String getTitle() {
		return title;
	}

	public void setTitle(String title) {
		this.title = title;
	}
  	public String getDirid() {
		return dirid;
	}

	public void setDirid(String dirId) {
		this.dirid = dirId;
	}
  	public String getResourceid() {
		return resourceid;
	}

	public void setResourceid(String resourceId) {
		this.resourceid = resourceId;
	}
  	public String getUrl() {
		return url;
	}

	public void setUrl(String url) {
		this.url = url;
	}
  	public java.util.Date getInputtime() {
		return inputtime;
	}

	public void setInputtime(java.util.Date inputtime) {
		this.inputtime = inputtime;
	}
  	public String getInputuser() {
		return inputuser;
	}

	public void setInputuser(String inputuser) {
		this.inputuser = inputuser;
	}
  	public Integer getStatus() {
		return status;
	}

	public void setStatus(Integer status) {
		this.status = status;
	}

	public String getS_url() {
		return s_url;
	}

	public void setS_url(String s_url) {
		this.s_url = s_url;
	}

	public String getBlogcid() {
		return blogcid;
	}

	public void setBlogcid(String blogCid) {
		this.blogcid = blogCid;
	}

	public Integer getReadtimes() {
		return readtimes;
	}

	public void setReadtimes(Integer readTimes) {
		this.readtimes = readTimes;
	}

	public Integer getReplynum() {
		return replynum;
	}

	public void setReplynum(Integer replyNum) {
		this.replynum = replyNum;
	}

	public String getHtmlurl() {
		return htmlurl;
	}

	public void setHtmlurl(String htmlUrl) {
		this.htmlurl = htmlUrl;
	}

	public String getCirclesn() {
		return circlesn;
	}

	public void setCirclesn(String circleSn) {
		this.circlesn = circleSn;
	}
	
	public String staticHtmlUrl() {
		String ret = "";
		if (this.inputtime != null) {
			ret = "/html/photo/" + df.format(this.inputtime) + "/" + this.cid + ".htm";
//			ret = "/"+domain+"/html/" + df.format(this.inputtime) + "/" + this.cid
//			+ ".htm";
		}
		return ret;
	}

	public static SimpleDateFormat getDf() {
		return df;
	}

	public String getIntro() {
		return intro;
	}

	public void setIntro(String intro) {
		this.intro = intro;
	}
	
  }
